#ifndef VECTOR_H
#define VECTOR_H
#include "point.h"

class Vector
{
public:
    Vector() = default;
    Vector(const float& x,const float& y,const float& z):m_x(x),m_y(y),m_z(z){};
    Vector(const Point& point):m_x(point.m_x),m_y(point.m_y),m_z(point.m_z){};
    void operator= (const Point& rhs);
    friend float  operator* (const Vector& lhs, const Vector& rhs);
    friend Vector operator* (const Vector& lhs, const float& rhs);
    friend Vector operator* (const float& lhs, const Vector& rhs);
    friend Vector operator^ (const Vector& lhs, const Vector& rhs);
    friend Vector operator+ (const Vector& lhs, const Vector& rhs);

    float& operator[](int i);
    const float& operator[](int i) const;

    void normalized();
    float m_x{0.f};
    float m_y{0.f};
    float m_z{0.f};
};

#endif // VECTOR_H
